<template>
  <div class="home">
      <home-header></home-header>
      <home-swiper :list = "swiperList"></home-swiper>
      <home-icon :list = "iconList"></home-icon>
      <home-hot :list = "hotList"></home-hot>
      <home-weekend :list = "weekendList"></home-weekend>
  </div>
</template>

<script>
import HomeWeekend from './components/Weekend'
import HomeHeader from './components/Header'
import HomeSwiper from './components/Swiper'
import HomeIcon from './components/Icon'
import HomeHot from './components/Hot'
export default {
    name:'Home',
    components:{
      HomeHeader,
      HomeSwiper,
      HomeIcon,
      HomeHot,
      HomeWeekend
    },
    data(){
      return{
        swiperList:[],
        iconList:[],
        hotList:[],
        weekendList:[]
      }
    },
    mounted(){
      this.$axios.post("/api/imgList")
      .then(res=>{
        console.log(res)
        this.swiperList = res.data.data.swiperList
        this.iconList = res.data.data.iconList
        this.hotList = res.data.data.recommendList
        this.weekendList = res.data.data.weekendList
      })
    }
}
</script>

<style>
</style>